package com.juhuixing.feign.module.user.service;


import com.juhuixing.feign.module.user.aspect.DefaultErrDesc;
import com.juhuixing.common.assembly.trans.TransConfiguration;
import com.juhuixing.common.base.ResponseData;
import com.juhuixing.common.vo.UserVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 功能描述: 用户服务feign
 * @author: 刘猛
 * @date: 2019/3/13 13:20
 **/
@FeignClient(name = "shop-user-service",configuration = TransConfiguration.class)
@RequestMapping("/user")
public interface UserFeignService {

    @DefaultErrDesc
    @GetMapping("/findByUsername")
    ResponseData<UserVO> findByUsername(@RequestParam("username") String username);
}
